package jeconbond.Q.computation;

public class ProdPossProgressFunc implements IProgressFunc {
	static { System.out.println("OLD_EXPERIMENT Remove IProgressFunc"); }
	
	private double tankMul;
	private double traktorMul;

	public ProdPossProgressFunc(double tankMul, double traktorMul) {
		this.tankMul = tankMul;
		this.traktorMul = traktorMul;
	}

	@Override
	public void compute(double part, double[] out) {
		double tankPart = part;
		double traktorPart = 1.0 - tankPart;
		tankPart = Math.sqrt(tankPart);
		traktorPart = Math.sqrt(traktorPart);
		out[0] = tankPart * tankMul;
		out[1] = traktorPart * traktorMul;
	}
}
